home *** CD-ROM | disk | FTP | other *** search
- Path: uunet!zephyr.ens.tek.com!tekred!saab!billr
- From: billr@saab.CNA.TEK.COM (Bill Randle)
- Newsgroups: comp.sources.games
- Subject: v09i031: castle - adventure game with character graphics, Patch1
- Message-ID: <5256@tekred.CNA.TEK.COM>
- Date: 27 Feb 90 17:16:58 GMT
- Sender: news@tekred.CNA.TEK.COM
- Lines: 158
- Approved: billr@saab.CNA.TEK.COM
-
- Submitted-by: Bill Randle <billr@saab.CNA.TEK.COM>
- Posting-number: Volume 9, Issue 31
- Archive-name: castle/Patch1
- Patch-To: castle: Volume 8, Issue 93-97
-
- [There were several places where char arrays were being
- overwritten, causing lockup and core dumps. Thanks to
- mark@bit.uucp for finding and fixing the string[] problem.
- -br]
-
- #! /bin/sh
- # This is a shell archive. Remove anything before this line, then unpack
- # it by saving it into a file and typing "sh file". To overwrite existing
- # files, type "sh file -c". You can also feed this as standard input via
- # unshar, or by typing "sh <file", e.g.. If this archive is complete, you
- # will see the following message at the end:
- # "End of shell archive."
- # Contents: patches01
- # Wrapped by billr@saab on Tue Feb 27 09:12:31 1990
- PATH=/bin:/usr/bin:/usr/ucb ; export PATH
- if test -f 'patches01' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'patches01'\"
- else
- echo shar: Extracting \"'patches01'\" \(2838 characters\)
- sed "s/^X//" >'patches01' <<'END_OF_FILE'
- X*** /dev/null Tue Feb 27 09:00:03 1990
- X--- INCLUDE/patchlevel.h Tue Feb 27 09:08:55 1990
- X***************
- X*** 0 ****
- X--- 1 ----
- X+ #define PATCHLEVEL 1
- X*** INCLUDE/castle.h.orig Tue Feb 27 09:08:27 1990
- X--- INCLUDE/castle.h Tue Feb 27 09:08:32 1990
- X***************
- X*** 150,156 ****
- X
- X char levels[7][24][76];
- X short screens[35][12][27];
- X! char string[9];
- X int known[20];
- X short lvl_att[36];
- X static int exp[37] = {
- X--- 150,156 ----
- X
- X char levels[7][24][76];
- X short screens[35][12][27];
- X! char string[20];
- X int known[20];
- X short lvl_att[36];
- X static int exp[37] = {
- X*** files.c.orig Thu Feb 22 15:52:50 1990
- X--- files.c Mon Feb 26 15:58:47 1990
- X***************
- X*** 46,53 ****
- X Copyright() PSC
- X */
- X
- X! char files[20];
- X! char f_nam[80];
- X
- X get_levels()
- X {
- X--- 46,53 ----
- X Copyright() PSC
- X */
- X
- X! char files[128];
- X! char f_nam[128];
- X
- X get_levels()
- X {
- X*** monster.c.orig Wed Feb 21 12:14:56 1990
- X--- monster.c Tue Feb 27 09:06:16 1990
- X***************
- X*** 89,95 ****
- X monst_att(mon);
- X break;
- X case 'r' :
- X! case 'R' : if(!run_att)
- X if(rand()%18 + 3 < char_stats.dexterity)
- X run_away = TRUE;
- X else{
- X--- 89,95 ----
- X monst_att(mon);
- X break;
- X case 'r' :
- X! case 'R' : if(!run_att) {
- X if(rand()%18 + 3 < char_stats.dexterity)
- X run_away = TRUE;
- X else{
- X***************
- X*** 97,102 ****
- X--- 97,106 ----
- X print_mess("You can\'t get away!",2,0);
- X wrefresh(message_win);
- X }
- X+ }else{
- X+ print_mess("You can\'t get away!",2,0);
- X+ wrefresh(message_win);
- X+ }
- X break;
- X case 'l' :
- X case 'L' :
- X***************
- X*** 377,383 ****
- X wmove(inv_win,0,0);
- X wprintw(inv_win,"Use which Item?");
- X wmove(inv_win,1,0);
- X! wprintw(inv_win,"N)ext P)rev S)elect");
- X wmove(inv_win,3,0);
- X wprintw(inv_win,"%s",start->item);
- X wmove(inv_win,1,21);
- X--- 381,387 ----
- X wmove(inv_win,0,0);
- X wprintw(inv_win,"Use which Item?");
- X wmove(inv_win,1,0);
- X! wprintw(inv_win,"N)ext P)rev S)elect esc) to exit");
- X wmove(inv_win,3,0);
- X wprintw(inv_win,"%s",start->item);
- X wmove(inv_win,1,21);
- X*** store.c.orig Tue Feb 27 08:21:55 1990
- X--- store.c Tue Feb 27 08:22:00 1990
- X***************
- X*** 197,203 ****
- X int i = 0,j;
- X char in;
- X
- X! for(j=0;j<=20;j++)
- X string[j] = '\0';
- X wmove(message_win,row,col);
- X wrefresh(message_win);
- X--- 197,203 ----
- X int i = 0,j;
- X char in;
- X
- X! for(j=0;j<20;j++)
- X string[j] = '\0';
- X wmove(message_win,row,col);
- X wrefresh(message_win);
- X***************
- X*** 205,210 ****
- X--- 205,212 ----
- X {
- X in = string[i] = getch();
- X if(in == 0x08 || in == 0x7f){
- X+ if(i == 0)
- X+ continue;
- X i--;
- X wmove(message_win,row,col+i);
- X wprintw(message_win,"%c",' ');
- END_OF_FILE
- if test 2838 -ne `wc -c <'patches01'`; then
- echo shar: \"'patches01'\" unpacked with wrong size!
- fi
- # end of 'patches01'
- fi
- echo shar: End of shell archive.
- exit 0
-